package com.lipeng.mapper;

import com.lipeng.bean.User;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UserMapper {
    int deleteByPrimaryKey(Integer uid);

    int insert(User record);

    int insertSelective(User record);

    User selectByPrimaryKey(Integer uid);

    int updateByPrimaryKeySelective(User record);

    int updateByPrimaryKey(User record);

    List<User> selectAllUser();

    List<User> selectUserByName(@Param("name") String name);

    int changeState(@Param("ustate") Integer ustate,@Param("uid") Integer uid);

    User doLogin(@Param("uname") String uname,@Param("upsw") String upsw);

    User findUserByName(String name);

}